package com.gdssoft.pdaweb.dao.am.impl;

/*
 *  捷达世软件(深圳)有限公司
 *  Copyright (C) 2008-2010 ShenZhen JieDaShi Software Limited Company.
 */

import java.util.List;

import com.gdssoft.core.dao.impl.BaseDaoImpl;
import com.gdssoft.pdaweb.dao.am.AmPlanDao;
import com.gdssoft.pdaweb.model.am.AmPlan;
import com.gdssoft.pdaweb.model.water.WaterMeterPlan;

@SuppressWarnings("unchecked")
public class AmPlanDaoImpl extends BaseDaoImpl<AmPlan> 
implements AmPlanDao {

	public AmPlanDaoImpl() {
		super(AmPlan.class);
	}

	@Override
	public List<AmPlan> listOpeningPlans() {
		String hql="from AmPlan where planStatus=1";
		return this.findByHql(hql);
	}
	public List<AmPlan> getByPlanId(Long plantId){
		String hql="from AmPlan where planId=?";
		return this.findByHql(hql, new Object[]{plantId});
	}
}
